The invention relates to a method enabling digital, serial communication over an interface between an electronic device and a battery attached thereto, said digital, serial communication comprising transmission of bytes consisting of a number of bits, each bit being defined by one of a high level and a low level, wherein a leading bit of each byte is of a first one of said high and low levels. Further, the invention relates to an apparatus comprising an electronic device and a battery attached thereto, and to a battery.
In recent years the cellular telephone technology has developed rapidly and thus created a similar need for development in the area of batteries and battery packs, and more specifically, for communicating between a battery and an electronic device, such as a cellular telephone. Cellular telephones must utilize batteries in order to provide mobile capabilities. The battery is critical to the user of a cellular telephone, since the battery provides the ability to move about freely without being tied to a stationary power source.
Thus, in order to maximize the use of a cellular telephone, and other portable electronic devices, it is important that a user achieves maximum performance from the attached battery. This may be achieved by correctly charging the battery and always being able to identify the exact charging status of the battery. This enables the user to know how much standby time is left on the phone. This type of information enables the user to intelligently decide whether the charge in a battery is sufficient for his needs, or whether charging of the battery is required.
Recent developments of battery and battery pack related technologies have provided users with so-called xe2x80x9csmartxe2x80x9d batteries which can provide a user with a power source for an electronic device and further provide data transmission capabilities between the battery and the attached electronic device. This type of batteries may include storage means containing various data representing information which may be presented to a user, e.g. in a display of the portable device. The information in a battery may include an identification number, the maximum capacity, the present capacity, etc.
Some information from the battery is only used internally in the portable electronic device, while other information from the battery can be presented to the user, e.g. after having been processed by a processor in the battery or in the portable electrical device. For example, the stored information about the maximum capacity of the battery can be used in the electronic device only, while the current capacity may be calculated by the electronic device using the maximum capacity (or a previous value of the current capacity) and knowledge about the power consumption of the electronic device.
Therefore, information is exchanged between the electronic device and the battery by means of e.g. digital, serial communication over an interface between an electronic device and a battery attached thereto.
Such communication also needs some sort of handshaking in order to ensure that the communication is working correctly. Many protocols are known from the computer technology. However, these techniques, while satisfactory in a computer environment, are too complex and expensive for use with smaller and cheaper electronic devices, such as a cellular telephone. A simple, minimal protocol for serial communication is needed.
Therefore, it is an object of the invention to provide a method of the above-mentioned type which can overcome the described limitations, i.e. a method that is simple and cheap to implement.
In accordance with the invention, this object is accomplished in that the method comprises the step of transmitting the other of said high and low levels for a first period of time immediately prior to said leading bit.
When the leading bit of a byte is always of the same level (i.e. either high or low) and a period of the opposite level precedes the leading bit, it is very easy and simple to ensure that the sending as well as the receiving party is ready for the communication to take place and adjusted to the actual direction of communication.
As stated in claim 2, the method may further comprise the steps of transmitting each byte with a trailing bit of the other of said high and low levels, and transmitting the other of said high and low levels for a second period of time immediately following said trailing bit. When a period of the opposite level also follows the trailing bit of the byte, the interface is left in a state where it is ready for the next state to be transmitted.
As stated in claim 3, the sum of said first and second periods of time may define a waiting state between two consecutive bytes in the case where at least two bytes are transmitted following each other. This waiting state may be used for a change of the direction of transmission, as stated in claim 4. Further, as stated in claim 5, a byte transmitted in one direction over said interface may be retransmitted in the opposite direction after the direction of transmission has been changed, which enables a simple error detection.
If, as stated in claim 6, the second period of time exceeds a preset value, the interface may be set to an idle state wherein the first one of said high and low levels is transmitted. By setting the interface to an idle state it is possible to turn off the circuitry placed in the battery. This means that this circuitry is only powered up when needed for transmission, and thus energy from the battery can be conserved.
As stated in claim 7, said first period of time may define a wake-up state when a byte is transmitted as the first byte after an idle state. This means that the circuitry in the battery will have time for power-up and initiation before the byte is transmitted.
As mentioned, the invention further relates to an apparatus comprising an electronic device, a battery attached thereto, and means enabling digital, serial communication over an interface between the electronic device and the battery, and comprising first communications circuitry in the electronic device and second communications circuitry in the battery, said digital, serial communication comprising transmission between said first and second communications circuitry of bytes consisting of a number of bits, each bit being defined by one of a high level and a low level, wherein a leading bit of each byte is of a first one of said high and low levels.
When at least one of said first and second communications circuitry is adapted to transmit the other of said high and low levels for a first period of time immediately prior to said leading bit, an apparatus of the above-mentioned type capable of overcoming the described limitations is provided, i.e. an apparatus that is simple and cheap to implement. Thus it is very easy and simple to ensure that the sending as well as the receiving party is ready for the communication to take place and adjusted to the actual direction of communication.
Expedient embodiments of the apparatus are described in claims 9 to 14 having the benefits mentioned above. Further, as stated in claim 15, the electronic device may expediently be a cellular telephone.
As mentioned, the invention further relates to a battery comprising means enabling digital, serial communication over an interface between the battery and an electronic device, and comprising communications circuitry in the battery, said digital, serial communication comprising transmission between said communications circuitry and the electronic device of bytes consisting of a number of bits, each bit being defined by one of a high level and a low level, wherein a leading bit of each byte is of a first one of said high and low levels.
When said communications circuitry is adapted to transmit the other of said high and low levels for a first period of time immediately prior to said leading bit, a battery of the above-mentioned type capable of overcoming the described limitations is provided, i.e. a battery that is simple and cheap to implement. Thus it is very easy and simple to ensure that the sending as well as the receiving party is ready for the communication to take place and adjusted to the actual direction of communication.
Expedient embodiments of the battery are described in claims 17 to 22 having the benefits mentioned above.